﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;


using vi = AnasisIskatmani;

namespace Anasis
{
    public partial class SistemYoneticisiForm : Form
    {
        
        public SistemYoneticisiForm()
        {
            InitializeComponent();
        }
       
        private void sekreterIslemleriniGetirToolStripMenuItem_Click(object sender, EventArgs e)
        {
            if (this.ActiveMdiChild == null)
            {
                SekreterFrm sekreterfrm = new SekreterFrm();
                sekreterfrm.MdiParent = this;
                //sekreterfrm.StartPosition = FormStartPosition.CenterParent;
                sekreterfrm.Show();
            }

        }

        private void ogretmenIslemleriniGetirToolStripMenuItem_Click(object sender, EventArgs e)
        {
            if (this.ActiveMdiChild==null)
            {
                OgretmenFrm ogretmenfrm = new OgretmenFrm(Convert.ToInt32(cmbSistemOgretmen.SelectedValue));
                ogretmenfrm.MdiParent = this;
                //ogretmenfrm.StartPosition = FormStartPosition.WindowsDefaultBounds;
                ogretmenfrm.Show();
                
                
            }

        }

        private void uyelikBilgileriniYonetToolStripMenuItem_Click(object sender, EventArgs e)
        {
            if (this.ActiveMdiChild == null)
            {
                FrmUyelik frmuyelik = new FrmUyelik();
                frmuyelik.MdiParent = this;
                frmuyelik.Show();
            }
        }

        private void sekreterBilgileriniYonetToolStripMenuItem_Click(object sender, EventArgs e)
        {
            if (this.ActiveMdiChild == null)
            {
                FrmSekreterYonet frmSekreterYonet = new FrmSekreterYonet();
                frmSekreterYonet.MdiParent = this;
                frmSekreterYonet.Show();
            }
        }

        private void SistemYoneticisiForm_Load(object sender, EventArgs e)
        {
            cmbSistemOgretmen.DataSource = vi.Calisan.ogretmenGetir();
            cmbSistemOgretmen.DisplayMember = "calisanTam";
            cmbSistemOgretmen.ValueMember = "calisan_id";

        }
    }
}
